#ifndef POPUP_H_
#define POPUP_H_

#include <wx/wx.h>
#include "../../core/Buddy.h"
#include <wx/event.h>
#include "PopupService.h"
#include "../StdUserInterfaceModule/ImppPopupWindow.h"

namespace Impp
{

class PopupService;


class Popup: public ImppPopupWindow
{
private:
	PopupService* service;
	time_t createTime;
	Buddy* buddy;
	wxString txt;
	int time;


public:
	Popup(PopupService* service, const wxPoint & pos,const wxSize & size, Buddy* buddy, const wxString & txt,const wxColor & color, int time);
	virtual ~Popup();

	bool isTimedOut(time_t & now);

private:
	void onLeftDown(wxMouseEvent & event);
	void onRightDown(wxMouseEvent & event);

private:
	DECLARE_EVENT_TABLE()


};

}

#endif /*POPUP_H_*/
